
    <!DOCTYPE html>
    <html lang="zh-CN">
    <head>
      <meta charset="UTF-8">
      <meta name="viewport" content="width=device-width, initial-scale=1.0">
      <title>Jenkins - 学习卡片</title>
      <style>
        body { font-family: sans-serif; background-color: #f0f8ff; color: #333; display: flex; flex-direction: column; align-items: center; padding: 50px 20px; }
        .header h1 { font-size: 32px; }
        .grid-container { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; width: 100%; max-width: 1200px; }
        .card-container { perspective: 1200px; cursor: pointer; height: 250px; }
        .card { width: 100%; height: 100%; position: relative; transform-style: preserve-3d; transition: transform 0.7s; border-radius: 16px; box-shadow: 0 4px 16px rgba(0,0,0,0.08); }
        .card-container.flipped .card { transform: rotateY(180deg); }
        .card-face { position: absolute; width: 100%; height: 100%; backface-visibility: hidden; display: flex; flex-direction: column; box-sizing: border-box; border-radius: 16px; background-color: #fff; padding: 24px; }
        .card-back { background-color: #f0fff4; transform: rotateY(180deg); justify-content: space-between; }
        .card-category { font-size: 14px; color: #0052d9; margin-bottom: 8px; font-weight: 500; }
        .card-question { font-size: 20px; font-weight: 500; flex-grow: 1; display: flex; align-items: center; justify-content: center; text-align: center; }
        .card-answer-wrapper { flex-grow: 1; overflow-y: auto; }
        .card-answer { font-size: 15px; line-height: 1.7; }
        .card-footer { font-size: 13px; color: #8a919f; border-top: 1px solid #f0f0f0; padding-top: 16px; margin-top: 16px; }
        .card-source { font-size: 13px; color: #8a919f; border-top: 1px solid #f0f0f0; padding-top: 12px; margin-top: 12px; }
      </style>
    </head>
    <body>
      <div class="header">
        <h1>Jenkins - 学习卡片</h1>
      </div>
      <div class="grid-container">
        
    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">理论</div>
          <div class="card-question">什么是持续集成（Continuous Integration）？它的核心实践是什么？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">理论</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">持续集成（CI）是一种软件开发实践，指只要代码有变更，就自动运行构建和测试，并反馈运行结果。其核心实践是开发人员提交新代码后，立刻进行构建和（单元）测试，以确定新代码和原有代码能否正确地集成在一起。</div>
          </div>
          <div class="card-source">来源: 2.1 持续集成（Continuous Integration)</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">理论</div>
          <div class="card-question">持续交付（Continuous Delivery）与持续集成的关系是什么？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">理论</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">持续交付是在持续集成的基础上进行的扩展。它将经过持续集成（构建和单元测试）后的代码，自动部署到更贴近真实运行环境（如类生产环境）中进行更多的测试。如果代码没有问题，可以继续手动部署到生产环境。</div>
          </div>
          <div class="card-source">来源: 2.2 持续交付（Continuous Delivery）</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">理论</div>
          <div class="card-question">在持续集成的语境下，如何区分“部署（Deployment）”和“发布（Release）”？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">理论</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">部署（Deployment）指的是应用组件或基础设施的代码或配置变更在生产环境生效。而发布（Release）则是指具有业务影响的功能变化对最终用户可见。频繁部署可以降低风险，同时业务负责人仍能控制何时向用户发布功能。</div>
          </div>
          <div class="card-source">来源: 2.4 持续集成中关键词解释</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">特性</div>
          <div class="card-question">根据文档，实施持续集成（CI）可以带来哪些主要优点？请列举至少三项。</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">特性</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">实施持续集成的主要优点包括：1. 能够快速暴露错误；2. 保证代码提交质量；3. 定位错误更加容易；4. 降低整体集成风险；5. 促进产品快速迭代。</div>
          </div>
          <div class="card-source">来源: 3.持续集成优点</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">机制</div>
          <div class="card-question">文档中描述的基于Jenkins的典型部署流程包含哪几个步骤？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">机制</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">典型的部署流程包含四个步骤：1. 用户提交代码到Git仓库；2. Jenkins服务器从Git拉取代码，使用Maven编译打包；3. Jenkins通过SSH将包传送到应用服务器；4. Jenkins在应用服务器上远程执行脚本以重启应用或启动项目。</div>
          </div>
          <div class="card-source">来源: 5. 部署流程</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">技术</div>
          <div class="card-question">Jenkins是什么？它通常与哪些类型的工具结合使用？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">技术</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">Jenkins是一个开源的、提供友好操作界面的持续集成(CI)工具，主要用于持续、自动地构建和测试软件项目。它通常与版本管理工具（如SVN、GIT）和构建工具（如Maven、Ant、Gradle）结合使用。</div>
          </div>
          <div class="card-source">来源: 6. Jenkins安装 > Jenkins是什么</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">配置</div>
          <div class="card-question">在Jenkins中配置项目以实现远程发布时，如果找不到“Deploy war/ear to a container”选项，应该怎么做？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">配置</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">如果在配置项目时找不到“Deploy war/ear to a container”选项，说明没有安装“Deploy to container”插件。需要去Jenkins的插件管理中搜索并安装这个插件。</div>
          </div>
          <div class="card-source">来源: 11.4 配置项目远程发布</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">机制</div>
          <div class="card-question">如何配置Gitee仓库，使其在代码提交时能自动触发Jenkins构建？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">机制</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">首先在Jenkins项目的配置中找到并启用“触发远程构建”，获取一个自动构建地址。然后将这个地址配置到Gitee项目仓库的WebHooks设置中，这样代码提交时Gitee就会通知Jenkins执行构建。</div>
          </div>
          <div class="card-source">来源: 12.2 把自动构建地址配置到Gitee的WebHooks上</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">配置</div>
          <div class="card-question">为了让Gitee的WebHooks能够成功触发Jenkins构建，需要对Jenkins的哪一项全局安全设置进行修改？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">配置</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">需要关闭Jenkins的“防止跨站点请求伪造”（Prevent Cross Site Request Forgery）安全选项。该设置位于“全局安全配置”中。</div>
          </div>
          <div class="card-source">来源: 12.3 关闭Jenkins上的防止跨站点伪造</div>
        </div>
      </div>
    </div>

      </div>
    </body>
    </html>
